/*
 * @(#)LazySingleton.java    Aug 16, 2010
 *
 * Copyright 2009 Nyber Shanghai, Inc. All rights reserved.
 */

package com.lab.basic;

/**
 * Class description goes here.
 *
 * @author nickevin@gmail.com
 * @version Aug 16, 2010 8:25:34 PM
 */

public class LazySingleton {

    private static LazySingleton instance;

    private LazySingleton() {}

    public synchronized LazySingleton getInstance() {
        if (instance == null) {
            instance = new LazySingleton();
        }

        return instance;
    }
}
